package cn.net.sinodata.system.domain.bo;

import cn.net.sinodata.system.domain.PmUniqueElement;
import cn.net.sinodata.common.mybatis.core.domain.BaseEntity;
import cn.net.sinodata.common.core.validate.AddGroup;
import cn.net.sinodata.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 唯一性校验要素业务对象 pm_unique_element
 *
 * @author yinliangyun
 * @date 2025-10-30
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = PmUniqueElement.class, reverseConvertGenerate = false)
public class PmUniqueElementBo extends BaseEntity {

    /**
     * 主键
     */
    @NotBlank(message = "主键不能为空", groups = { EditGroup.class })
    private String id;

    /**
     * 要素英文名称
     */
    @NotBlank(message = "要素英文名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String enName;

    /**
     * 要素中文名称
     */
    @NotBlank(message = "要素中文名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String cnName;

    /**
     * 要素类型
     */
    @NotBlank(message = "要素类型不能为空", groups = { AddGroup.class, EditGroup.class })
    private String elementType;

    /**
     * 渠道编号
     */
    @NotBlank(message = "渠道编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String channelId;

    /**
     * 渠道名称
     */
    @NotBlank(message = "渠道名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String channelName;

    /**
     * 模板编号
     */
    @NotBlank(message = "模板编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String tempId;


    /**
     * 映射英文名称
     */
    private String mapElementEnName;

    /**
     * 要素长度
     */
    private String elementLength;

    /**
     * 备注
     */
    private String remarks;

}
